package com.sumainfor.pc.gmio.controller;

import com.sumainfor.common.util.JsonResult;
import com.sumainfor.pc.gmio.feign.Zfeign.ZpcMktFeign;
import com.sumainfor.pc.gmio.service.ButlerTableService;
import org.apache.http.HttpRequest;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.ResponseBody;

import java.util.Map;

/**
 * <p>
 * 服务管家工作台
 * <p>
 *
 * @author: zhoucong
 * @create: 2019-06-05 17:28
 **/
@Controller
@RequestMapping("/butlerTable")
public class ButlerTableController {

    @Autowired
    ButlerTableService butlerTableService;

    @Autowired
    ZpcMktFeign zpcMktFeign;

    /**
    * <p>
    * 重要状态提醒
    * </p>
    *
     *
    * @author: zhoucong
    * @since:
    */
    @ResponseBody
    @GetMapping("/getImport")
    public JsonResult getImport(@RequestParam Map<String,Object> params){

        return butlerTableService.getImport(params);
    }


    /**
    * <p>
    * 特殊事项
    * </p>
    *
    * @author: zhoucong
    * @since:
    */
    @ResponseBody
    @GetMapping("/specialConsiderations")
    public  JsonResult specialConsiderations(@RequestParam Map<String,Object> params){

        return butlerTableService.specialConsiderations(params);
    }

    /**
    * <p>
    * 本月续租数
    * </p>
    *
    * @author: zhoucong
    * @since:
    */
    @ResponseBody
    @GetMapping("/getForRenewal")
    public JsonResult getForRenewal(){
        return zpcMktFeign.getForRenewal();
    }


}
